/***************************************************************************
 *  @file       main.cpp
 *  @author     Alan.W
 *  @date       12  Jan 2014
 *  @remark     This code is for the exercises from C++ Primer 5th Edition
 *  @note
 ***************************************************************************/
//!
//! Exercise 14.16:
//! Define equality and inequality operators for your StrBlob (§ 12.1.1, p. 456),
//! StrBlobPtr (§ 12.1.6, p. 474), StrVec (§ 13.5, p. 526), and String (§ 13.5, p. 531)
//! classes.
//!
//!
//! Exercise 14.17:
//! Should the class you chose for exercise 7.40 from § 7.5.1 (p. 291) define
//! the equality operators? If so, implement them. If not, explain why not.
//!
#include <iostream>
#include <vector>

#include "Sales_data.h"
#include "block.h"
#include "StrBlob.h"
#include "strvec.h"
#include "string.h"

int main()
{
    std::vector<Block::Pointer> vl, vr;

    for(unsigned i =0 ; i != 10; ++i )
    {
        static bool flag = false;
        vl.push_back(std::make_shared<bool>(flag));
        vr.push_back(std::make_shared<bool>(flag));

        flag = !flag;
    }

    const Block lhs(8, vl, std::make_shared<bool>(true));
    const Block rhs(8, vr, std::make_shared<bool>(true));

    std::cout << (lhs == rhs) << " " << (lhs != rhs) << "\n";

    return 0;
}







